<template>
  <div class="nav-content w">
    <!-- 幻灯片 -->
    <el-carousel :interval="3000" arrow="always">
      <el-carousel-item v-for="(item,index) in imgList" :key="index">
        <img :src="item.src" style="height:100%;width:100%;" alt="图片丢失了" :title="item.title" />
      </el-carousel-item>
    </el-carousel>
    <!-- 秒杀 -->
  </div>

</template>

<script>
export default {
  data() {
    return {
      imgList: [
        {
          name: "lj",
          src: require("../images/1.jpg"),
          title: "这是lj.png"
        },
        {
          name: "logo",
          src: require("../images/2.jpg"),
          title: "这是logo.png"
        },
        {
          name: "bg",
          src: require("../images/3.jpg"),
          title: "这是bg.png"
        },
        {
          name: "sadmas",
          src: require("../images/4.jpg"),
          title: "这是sadmas.png"
        }
      ]
    }
  }
}
</script>

<style scoped>
.nav-content {
  margin-top: 20px;
}
</style>